#ifndef QCARVEBITMAP_H
#define QCARVEBITMAP_H

#include "cx_typedef.h"
#include "QWString.h"
#include "QSize.h"

//class CFbsBitmap;
class CQBitmap
{
public:
    IMPORT_C CQBitmap(/*QINT aWidth, QINT aHeight*/);
    IMPORT_C ~CQBitmap();

public:
    IMPORT_C QBOOL LoadData(CQWString& wstrResPath, QINT offset);
    IMPORT_C QBOOL CopyFrom(const CQBitmap& bmpSrc) ;
    IMPORT_C QVOID Gray() ;
    //IMPORT_C QBOOL GetFbsBitmap(CFbsBitmap& rBitmap, CFbsBitmap* pMaskBitmap = NULL) const;
    //IMPORT_C QBOOL DrawFbsBitmap(CFbsBitmap& backBitmap, CQPoint pOri = CQPoint(0,0)) const;
    
    CQSize GetSize() const
    {
    	CQSize imgSize(m_Width,m_Height);
    	return imgSize;
    };
    QSHORT* GetLineRange() const
    {
    	return m_LineRange;
    };
    QBYTE* GetData() const
    {
    	return m_Data;
    };
    QINT16 GetFlag() const
    {
    	return m_Flag;
    };
    QINT16 GetHeight() const
    {
		return m_Height;
    };
    QINT16 GetWidth() const
    {
    	return m_Width;
    };
	QINT GetDataLen() const
	{
		return m_DataLen;
	}
protected:
    QINT16 m_Width;
    QINT16 m_Height;
    QINT16 m_Flag;
    
    QINT m_LRLen;
    QINT m_DataLen;
    QSHORT* m_LineRange;
    QBYTE* m_Data;

};

#endif //QCARVEBITMAP_H
